package com.yuyu.shop.infrastructure.persistence.convert;

import cn.hutool.core.bean.BeanUtil;
import com.yuyu.shop.domain.shop.DO.ShopInfoDO;
import com.yuyu.shop.infrastructure.persistence.po.ShopPO;

import java.util.Objects;

/**
 * @author \
 * @version 1.0
 * @description: TODO
 * @date 2022/8/4 16:59
 */
public class ShopPoConvert {

    public static ShopInfoDO PO2DO(ShopPO po){
        if (Objects.nonNull(po)){
            ShopInfoDO shopInfoDO = new ShopInfoDO();
            BeanUtil.copyProperties(po,shopInfoDO);
            return shopInfoDO;
        }
        return null;
    }
}
